package com.zpself.module.basic.观察者EventListener.Listener;

import com.zpself.module.basic.观察者EventListener.PushEvent;
import lombok.extern.slf4j.Slf4j;
import org.springframework.context.event.EventListener;
import org.springframework.stereotype.Service;

@Slf4j
@Service
public class EventListenerDemo1 {

    @EventListener
    public void eventListener(PushEvent event){
        log.info(this.getClass().getSimpleName()+"监听到数据："+event.getMsg());
    }
}
